package kt.processor.entity;

import java.sql.Date;

import kt.processor.MillionareUnlimitProcessor;

public class SessionIQ {
	private int id;
	public int getId() {
		return id;
	}
	public void setId(int id) {
		this.id = id;
	}
	public String getIsdn() {
		return isdn;
	}
	public void setIsdn(String isdn) {
		this.isdn = isdn;
	}
	public String getStatus() {
		return status;
	}
	public void setStatus(String status) {
		this.status = status;
	}
	public String getLucky_code() {
		return lucky_code;
	}
	public void setLucky_code(String luckyCode) {
		lucky_code = luckyCode;
	}
	public int getLast_ques_id() {
		return last_ques_id;
	}
	public void setLast_ques_id(int lastQuesId) {
		last_ques_id = lastQuesId;
	}
	public Date getLast_send_time() {
		return last_send_time;
	}
	public void setLast_send_time(Date lastSendTime) {
		last_send_time = lastSendTime;
	}
	public int getNo_of_ques_ans() {
		return no_of_ques_ans;
	}
	
	public int getQuestionPoint() {
		int point = 45;
		if(this.getNo_of_ques_ans() < 15){
			point = MillionareUnlimitProcessor.POINTS[this.getNo_of_ques_ans()];
		}
		return point;
	}
	
	public int getNextQuestionPoint() {
		int point = 45;
		if(this.getNo_of_ques_ans() + 1 < 15){
			point = MillionareUnlimitProcessor.POINTS[this.getNo_of_ques_ans() + 1];
		}
		return point;
	}
	
	public void setNo_of_ques_ans(int noOfQuesAns) {
		no_of_ques_ans = noOfQuesAns;
	}
	public Date getSession_start_time() {
		return session_start_time;
	}
	public void setSession_start_time(Date sessionStartTime) {
		session_start_time = sessionStartTime;
	}
	public Date getSession_end_time() {
		return session_end_time;
	}
	public void setSession_end_time(Date sessionEndTime) {
		session_end_time = sessionEndTime;
	}
	public String getLanguage() {
		return language;
	}
	public void setLanguage(String language) {
		this.language = language;
	}
	private String isdn;
	private String status;
	private String lucky_code;
	private int last_ques_id;
	private Date last_send_time;
	private int no_of_ques_ans;
	private Date session_start_time;
	private Date session_end_time;
	private String language;
	
	@Override
	public String toString() {
		return "SessionIQ [id=" + id + ", isdn="
				+ isdn + ", status=" + status + ", language=" + language + "]";
	}
}
